import {LitElement ,html} from 'lit-element';
import md5 from 'js-md5';

class MyLogin extends LitElement {

    constructor(){
        super();
        this.username;
        this.password;
        
    }
    
    render(){
      return html`
          <input type='text' @keyup=${this.inputUsername}>
          <input type='text' @keyup=${this.inputPassword}>
          <button @click=${this.login}>login</button>
        `;
    }

    inputUsername(e){
        this.username = e.target.value;
    }

    inputPassword(e){
       this.password = e.target.value;
       
    }
    login(){
        console.log(`${this.username}--${this.password}`);
    }
    
}
customElements.define('my-login', MyLogin);
